<!DOCTYPE html>
<html>
	<head>  
		<meta charset="utf-8">
		<title>index</title>
		<meta name="referrer" content="never" />
		<meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="apple-mobile-web-app-status-bar-style" content="black">
		<link rel="stylesheet" href="../../../../css/mui.min.css">
		<link rel="stylesheet" href="../../static/components/components.css" />
		<link rel="stylesheet" href="../../static/css/common.css">
		<link rel="stylesheet" type="text/css" href="../../../../css/preview.css" />
		<link rel="stylesheet" type="text/css" href="../../../../css/mui.picker.min.css" />
		<link rel="stylesheet" type="text/css" href="../../../../css/mui.poppicker.css" />
		<link rel="stylesheet" type="text/css" href="../../../../css/mui.picker.css" />
		<style>
			.mui-bar-nav ~ .mui-content .mui-pull-top-pocket{
				top:180px !important;
			}
			.select-box{
				overflow: hidden;
				text-overflow: ellipsis;
				white-space: nowrap;
			}
			.label{
				width: 18vw;
			}
			.item-title{
			width: 20vw;
			}
			.list-head{
				width: 94vw;
				margin-left: 3vw;
				background-color: #fff;
				padding: 10px;
				margin-bottom: 10px;
			}
			.myheigth {
				height: 9vw;
			}
			.list button{
				margin: 0 !important;
				padding: 0 4vw !important;
			}
			.itme-content{
				width: 45vw !important;
				height: 30px;
				line-height: 30px;
			}
		</style>
	</head>

	<body>

		<header class="mui-bar mui-bar-nav mui-bar-nav-bg">
			<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
			<h1 id="title" class="mui-title">光伏电场巡检</h1>
		</header>
		<div class="mui-content" id="content" v-cloak>
			<div style="position: sticky;top: 45px;z-index: 11;" class="flex-between list-head">
				<div class="flex-row" style="font-weight: bold;">
					<div class="icon"></div>
					本次检查记录
				</div>
				<button @tap="add" class="submit_btn" style="	margin: 0 !important;
					padding: 0 4vw !important;">新增</button>
			</div>
			<div id="scroll">
				<div class="list" id="list">
					<div v-for="(item,index) in photFarmForm.list" :key="index">
						<div>
							<div class="flex-between">
								<div>
									<div class="flex-row">
										<div class="flex-row">
											<span class="label">场站名称</span>
											<div class="select-box" @click="showStationList(index)" style="width: 40vw;" class="item-title">{{item.stationName || '请选择'}}</div>
										</div>
									</div>

									<div class="flex-row">
										<div class="label">巡视人</div>
										<div>{{baseForm.checkName}}{{baseForm.checkDate}}</div>
									</div>
								</div>
								<div class="">
									<button @tap="edit(item,index)"  v-if="isMyEditor" class="cancel_btn">编辑</button>
									<button style="color: white;background: red;border: 0;margin-top: 5px!important;" @tap="delPhotFarm(item)" v-if="isMyEditor" class="cancel_btn">删除</button>
								</div>
								
							</div>
						</div>
					</div>
					<div v-if="!isMyEditor" class="flex-row">
						<span class="label">其他情况</span>
						<textarea style="width: 70vw;" placeholder="无其他情况" v-model="elseDesc" disabled ></textarea>
					</div>
				</div>
			</div>
			<div class="popup-bg" v-if="addOrEdit">
				<div style="width:90vw;max-height: 80vh;padding: 15px 15px 0px;overflow: auto;" class="add-box" @click@tap.stop="clickStop">
					<div class="mt-10">
						<div class="flex-between myheigth m-10">
							<div>
								巡视时间 {{baseForm.checkDate}}
							</div>
						</div>
						<div class="flex-between myheigth m-10">
							<div>
								巡视人 {{baseForm.checkStaff}}
							</div>
						</div>
						<hr size="1" style="color: #999;border-style: dashed; widows: 250px;" />
						<div>逆变室</div>
						<div v-for="(items,indexs) in checkForm.nbList">
							<div class="flex-between myheigth m-10">
								<div>
									{{items.checkContent}} 
								</div>
								<div  class="flex-row" v-if="items.checkContent=='逆变器启动/停止'">
									<div v-for="it in startOrStop">
										{{it.itemText}}
										<input v-model="items.result" type="radio" :value="it.itemValue"
										 style="margin-right: 5px;width: 15px;" />
									</div>
									<!-- <input v-if="items.checkContent=='风俗功率是否匹配" @input="changeCheck" placeholder="请输入因温度停机台数" maxlength="60" v-model="formData.deviceName" class="itme-content"></input> -->
								</div>
								<div class="flex-row" v-else>
									<div v-for="it in normalOrNot">
										{{it.itemText}}
										<input v-model="items.result" type="radio" :value="it.itemValue"
										 style="margin-right: 5px;width: 15px;" />
									</div>
								</div>
							</div>
							<div class="flex-between myheigth m-10">
								备注<input @input="changeCheck" placeholder="请输入备注" maxlength="60" v-model="items.remark" class="itme-content"></input>
							</div>
						</div>
					<hr size="1" style="color: #999;border-style: dashed; widows: 250px;" />
					<div>箱变</div>
					<div v-for="(items,indexs) in checkForm.xbList">
						<div class="flex-between myheigth m-10">
							<div>
								{{items.checkContent}} 
							</div>
							<div class="flex-row">
								<div v-for="it in normalOrNot">
									{{it.itemText}}
									<input v-model="items.result" type="radio" :value="it.itemValue"
									 style="margin-right: 5px;width: 15px;" />
								</div>
							</div>
						</div>
						<div class="flex-between myheigth m-10">
							备注<input @input="changeCheck" placeholder="请输入备注" maxlength="60" v-model="items.remark" class="itme-content"></input>
						</div>
					</div>
						<hr size="1" style="color: #999;border-style: dashed; widows: 250px;" />
								<div>汇流箱</div>
								<div v-for="(items,indexs) in checkForm.hlList">
									<div class="flex-between myheigth m-10">
										<div>
											{{items.checkContent}} 
										</div>
										<input @input="changeCheck" placeholder="请输入" maxlength="60" :onkeyup="items.result = items.result.replace(/\s+/g,'')" v-model="items.result" class="itme-content"></input>
									</div>
									<div class="flex-between myheigth m-10">
										备注<input @input="changeCheck" placeholder="请输入备注" maxlength="60" v-model="items.remark" class="itme-content"></input>
									</div>
								</div>		
					</div>
					<div class="pop-bottom">
						<div @tap="addList">{{isEdit?'修改':'添加'}}</div>
						<div class="color-red" @tap="clearFormateData">取消</div>
					</div>
				</div>
			</div>
			<div style="height: 60px;">
			</div>
			<div class="flex-between fixed-bottom">
				<button @tap="save" class="submit_btn">保存</button>
				<!-- <button v-if="isShowHandle()" @tap="approveInitDefectInfo('back')" class="cancel_btn">
					退回
				</button> -->
				<!-- <button @tap="approveInitDefectInfo('approve')" class="submit_btn">通过</button> -->
				<button @tap="submit" class="submit_btn">提交</button>
				<button @click="goBack" class="cancel_btn">
					返回
				</button>
			</div>
		</div>
		<script src="../../../../js/mui.min.js"></script>
		<script src="../../../../js/vue.js"></script>
		<script src="../../static/js/neiosCommon.js"></script>  <!--公共js页面必需-->
		<script src="../../static/components/personSelect.js"></script>
		<!--人员查询组件-->
		<script type="text/javascript" src="../../static/js/neiosRequst.js"></script>
		<script type="text/javascript" src="../../../../js/jquery-3.2.1.min.js"></script>
		<script src="../../static/components/processLog.js"></script>  <!--流程日志-->
		<script src="./list.js"></script>
		<script src="../../../../js/mui.picker.js" type="text/javascript" charset="utf-8"></script>
		<script src="../../../../js/mui.poppicker.js"></script>
		<script src="../../../../js/mui.picker.min.js"></script>
		<script src="../../../../js/mui.dtpicker.js"></script>
	</body>

</html>
